<?
require( "Application.php"); 
$storeManager = new StoreManager();
$citySearchBuilder = new CitySearchBuilder();
$store = $storeManager->getStore($_GET["storeid"]);
$ar1 = $storeManager->getYelps($store->storeId);
$ar2 = $storeManager->getArticles($store->storeId);
$ar3 = array_merge((array)$ar2, (array)$ar1 );
$arCitySearch = $citySearchBuilder->getReviews($store->storeId, $store->lat, $store->lng, $store->yelpTerm);
//echo count($arCitySearch);
$articles = array_merge((array)$ar3, (array)$arCitySearch);
shuffle($articles);
echo json_encode($articles);
require( "OnRequestEnd.php"); 
?>